﻿@{
    Layout = null;
}
<!DOCTYPE>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>无标题页</title>
    <script src="@Url.Content("~/Scripts/jquery-1.6.2.min.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/Shared/jquery.form.js")" type="text/javascript"></script>
    <script src="@Url.Content("~/Scripts/base/cls-page.js")" type="text/javascript"></script>
    <script language="javascript" type="text/javascript">
        // prepare the form when the DOM is ready
        $(document).ready(function () {
            //commonPage.ajaxGrid();
        });

        // pre-submit callback 
        function showRequest(formData, jqForm, options) {
            // formData is an array; here we use $.param to convert it to a string to display it 
            // but the form plugin does this for you automatically when it submits the data 
            var queryString = $.param(formData);

            // jqForm is a jQuery object encapsulating the form element.  To access the 
            // DOM element for the form do this: 
            // var formElement = jqForm[0]; 

            alert('About to submit: \n\n' + queryString);

            // here we could return false to prevent the form from being submitted; 
            // returning anything other than false will allow the form submit to continue 
            return true;
        }

        // post-submit callback 
        function showResponse(responseText, statusText, xhr, $form) {
            // for normal html responses, the first argument to the success callback 
            // is the XMLHttpRequest object's responseText property 

            // if the ajaxForm method was passed an Options Object with the dataType 
            // property set to 'xml' then the first argument to the success callback 
            // is the XMLHttpRequest object's responseXML property 

            // if the ajaxForm method was passed an Options Object with the dataType 
            // property set to 'json' then the first argument to the success callback 
            // is the json data object returned by the server 

            //alert('status: ' + statusText + '\n\nresponseText: \n' + responseText +
            //'\n\nThe output div should have already been updated with the responseText.');
        } 

    </script>
</head>
<body>
    <form id="myForm1" name="myForm1">
    <div class="common-table-container">
        <div>
            <input id="Text1" type="text" name="name1" value="111111111" />
        </div>
    </div>
    <input id="Submit1" type="submit" value="submit" />
    <a href="javascript:void(0)" onclick="commonPage.ajaxGrid({form:'#myForm1'});$('#myForm1').submit();">aa</a>
    </form>
    <form id="myForm2" name="myForm2" action="/Home/StartMenu">
    <div class="common-table-container1">
        <div>
            <input id="Text1" type="text" name="name1" value="111111111" />
        </div>
    </div>
    <input id="Submit1" type="submit" value="submit" />
    <a href="javascript:void(0)" onclick="commonPage.ajaxGrid({target:'.common-table-container1',form:'#myForm2'});$('#myForm2').submit();">bb</a>
    </form>
</body>
</html>
